package com.xiaoq.shop.dto;

import org.apache.commons.lang3.builder.ToStringBuilder;

import java.io.Serializable;

/**
 * @author xinpeng created on 16/9/23-上午10:09.
 */
public class SKUDTO implements Serializable{

    private String shopId;
    private String spuCode;
    private String spuName;
    private String skuCode;
    private String specifications;//多个规格用分号";"隔开
    private String imageUrlOfSKU;

    private double price;  //原始价格（在商品发布时设置）

    private double discountPrice; //折扣价格（在限时折扣中设置）

    private double recommendPrice; //店长推荐价格（在单品推荐中设置）

    private int stocks;  //当前SKU的库存数量

    private String catalogCode; //类目编码

    private String catalogName; //类目名称

    private String spuCatalogCode; //spu分类编码

    private String spuCatalogName; //spu分类名称

    private int saleState ;  //商品销售状态  1:上架中;-1:已下架;

    private int promotionState;  //促销类型: 0原始价格,1微团购价格,2限时折扣价格,3店长推荐价格

    //---------------以下是设定的微团购信息-----------------
    private double groupPurchasePrice; //团购价格（在微团购中设置）

    private int minimumQuantityRequired4OneGroup; //最低成团人数

    private int maxmumQuantityOfGroups;  //最大开团个数

    private Long startTime; //开始时间

    private Long endTime; //结束时间

    private boolean isRestrictedPurchaing; //是否限购

    private int maxmumQuantityToPermitPurchased; //在团购中每人允许的最大购买数量

    public String getShopId() {
        return shopId;
    }

    public void setShopId(String shopId) {
        this.shopId = shopId;
    }

    public String getSpuCode() {
        return spuCode;
    }

    public void setSpuCode(String spuCode) {
        this.spuCode = spuCode;
    }

    public String getSpuName() {
        return spuName;
    }

    public void setSpuName(String spuName) {
        this.spuName = spuName;
    }

    public String getSkuCode() {
        return skuCode;
    }

    public void setSkuCode(String skuCode) {
        this.skuCode = skuCode;
    }

    public String getSpecifications() {
        return specifications;
    }

    public void setSpecifications(String specifications) {
        this.specifications = specifications;
    }

    public String getImageUrlOfSKU() {
        return imageUrlOfSKU;
    }

    public void setImageUrlOfSKU(String imageUrlOfSKU) {
        this.imageUrlOfSKU = imageUrlOfSKU;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public double getDiscountPrice() {
        return discountPrice;
    }

    public void setDiscountPrice(double discountPrice) {
        this.discountPrice = discountPrice;
    }

    public double getRecommendPrice() {
        return recommendPrice;
    }

    public void setRecommendPrice(double recommendPrice) {
        this.recommendPrice = recommendPrice;
    }

    public int getStocks() {
        return stocks;
    }

    public void setStocks(int stocks) {
        this.stocks = stocks;
    }

    public String getCatalogCode() {
        return catalogCode;
    }

    public void setCatalogCode(String catalogCode) {
        this.catalogCode = catalogCode;
    }

    public String getCatalogName() {
        return catalogName;
    }

    public void setCatalogName(String catalogName) {
        this.catalogName = catalogName;
    }

    public String getSpuCatalogCode() {
        return spuCatalogCode;
    }

    public void setSpuCatalogCode(String spuCatalogCode) {
        this.spuCatalogCode = spuCatalogCode;
    }

    public String getSpuCatalogName() {
        return spuCatalogName;
    }

    public void setSpuCatalogName(String spuCatalogName) {
        this.spuCatalogName = spuCatalogName;
    }

    public int getSaleState() {
        return saleState;
    }

    public void setSaleState(int saleState) {
        this.saleState = saleState;
    }

    public int getPromotionState() {
        return promotionState;
    }

    public void setPromotionState(int promotionState) {
        this.promotionState = promotionState;
    }

    public double getGroupPurchasePrice() {
        return groupPurchasePrice;
    }

    public void setGroupPurchasePrice(double groupPurchasePrice) {
        this.groupPurchasePrice = groupPurchasePrice;
    }

    public int getMinimumQuantityRequired4OneGroup() {
        return minimumQuantityRequired4OneGroup;
    }

    public void setMinimumQuantityRequired4OneGroup(int minimumQuantityRequired4OneGroup) {
        this.minimumQuantityRequired4OneGroup = minimumQuantityRequired4OneGroup;
    }

    public int getMaxmumQuantityOfGroups() {
        return maxmumQuantityOfGroups;
    }

    public void setMaxmumQuantityOfGroups(int maxmumQuantityOfGroups) {
        this.maxmumQuantityOfGroups = maxmumQuantityOfGroups;
    }

    public Long getStartTime() {
        return startTime;
    }

    public void setStartTime(Long startTime) {
        this.startTime = startTime;
    }

    public Long getEndTime() {
        return endTime;
    }

    public void setEndTime(Long endTime) {
        this.endTime = endTime;
    }

    public boolean isRestrictedPurchaing() {
        return isRestrictedPurchaing;
    }

    public void setRestrictedPurchaing(boolean restrictedPurchaing) {
        isRestrictedPurchaing = restrictedPurchaing;
    }

    public int getMaxmumQuantityToPermitPurchased() {
        return maxmumQuantityToPermitPurchased;
    }

    public void setMaxmumQuantityToPermitPurchased(int maxmumQuantityToPermitPurchased) {
        this.maxmumQuantityToPermitPurchased = maxmumQuantityToPermitPurchased;
    }

    @Override
    public String toString() {
        return ToStringBuilder.reflectionToString(this);
    }
}
